package com.heima.apis.comment;

import com.heima.model.common.dtos.ResponseResult;
import com.heima.model.wemedia.dtos.WmCommentLikeDto;
import com.heima.model.wemedia.dtos.WmCommentListDto;
import com.heima.model.wemedia.dtos.WmCommentRepayDto;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient("leadnews-comment")
public interface ICommentClient {

    /**
     * 远程获取评论详情
     * @param dto
     * @return
     */
    @PostMapping("/api/v1/comment/list")
    public ResponseResult getCommentList(@RequestBody WmCommentListDto dto, @RequestParam Integer apAuthorId);

    /**
     * 自媒体作者回复评论
     * @param dto
     * @return
     */
    @PostMapping("/api/v1/comment/repay")
    public ResponseResult commentRepay(@RequestBody WmCommentRepayDto dto);

    /**
     * 自媒体作者点赞评论
     * @param dto
     * @return
     */
    @PostMapping("/api/v1/comment/authorLike")
    public ResponseResult authorLike(@RequestBody WmCommentLikeDto dto);
}
